<!--
 * @Description: 
 * @Author: Cxy
 * @Date: 2024-02-27 10:38:54
 * @LastEditors: Cxy
 * @LastEditTime: 2024-02-28 10:34:33
 * @FilePath: \blogAdmin\play\src\views\example\theme.vue
-->
<script setup lang="ts">
import { configStore } from '@/stores/config'
const colorChange = () => {
  configStore.changeThemeAppearance(color.value)
}
const color = ref(configStore.config.themeAppearance)
const predefineColors = ref(['#409eff'])
</script>

<template>
  <el-card shadow="never">
    <template #header>
      <div class="card-header">
        <span>主题</span>
      </div>
    </template>
    <div>
      主题颜色
      <el-color-picker v-model="color" showAlpha :predefine="predefineColors" @change="colorChange" />
    </div>
  </el-card>
</template>
